<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>测试请求参数</title>
</head>
<body>
<h1>测试请求参数</h1>
<a th:href="@{/testServletAPI(username = 'admin',password = 123)}">测试使用servletAPI获取请求参数</a><br/>
<a th:href="@{/testParam(username = 'admin',password = 123)}">测试使用控制器的形参获取请求参数</a><br/>
<form th:action="@{/testForm}" method = "get">
    用户名 <input type = "text" name= "username"><br/>
    密码<input type = "password" name= "password"><br/>
    兴趣爱好<input type = "checkbox" name="hobby" value = "C++">C++
    <input type = "checkbox" name="hobby" value = "Java">Java<br/>
    <input type = "checkbox" name="hobby" value = "JavaScript">JavaScript<br/>
    <input type = "submit">
</form>

<form th:action="@{/testBean}" method = "post">
    用户名：<input type = "text" name = "username"><br/>
    密码：<input type = "password" name = "password"><br/>
    性别：<input type = "radio" name = "sex" value = "男">男<input type = "radio" name = "sex" value = "女">女<br/>
    年龄：<input type = "text" name = "age"><br/>
    邮箱：<input type = "text" name = "email"><br/>
    <input type = "submit" value = "确认提交">
</form>
</body>
</html>